package com.sdcx.agrobank.util;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;

import com.sdcx.agrobank.MainActivity;

/*
 *@Author:田恒宇
 *@Date: 2020-06-03
 *@Time:17:42
 *@Description:登录广播接收器
 */
public class LoginBroadcastReceiver extends BroadcastReceiver {
    @Override
    public void onReceive(Context context, Intent intent) {
        ActivityCollector.finishAll();  // 销毁所有活动
        Intent intent1 = new Intent(context, MainActivity.class);
        context.startActivity(intent1);
    }
}
